import fetch from 'common/src/utils/fetch'

export const pageUrl = '/api/electionservice/electionConstants/list';
/**
 * 选课常量列表
 */
export function getConstantList(data) {
    return fetch({
        url: '/api/electionservice/electionConstants/list',
        method: 'post',
        data: data
    });
}

/**
 * 新增
 */
export function addConstant(data) {
    return fetch({
        url: '/api/electionservice/electionConstants/add',
        method: 'post',
        data: data
    });
}
/**
 * 修改
 */
export function updateConstant(data) {
    return fetch({
        url: '/api/electionservice/electionConstants/update',
        method: 'post',
        data: data
    });
}

/**
 * 删除
 */
export function deleteConstant(data) {
    return fetch({
        url: '/api/electionservice/electionConstants/delete',
        method: 'post',
        data: data
    });
}

/**
 * 详情
 */
export function getDetailById(id) {
    return fetch({
        url: '/api/electionservice/electionConstants/getConstants?id='+id,
        method: 'get'
    });
}


